<?php

namespace app\admin\model\agent;

use app\admin\model\Admin;
use think\Model;

/**
 * Withdrawal
 */
class Withdrawal extends Model
{
    // 表主键
    protected $pk = 'withdrawal_id';

    // 表名
    protected $name = 'agent_withdrawal';

    // 自动写入时间戳字段
    protected $autoWriteTimestamp = true;
    protected $updateTime = false;

    public function agent ()
    {
        return $this->hasOne(Admin::class, 'id', 'agent_id');
    }

}